Skip to content

[cling] Compatibility with MacOSX27.0.sdk [v6.40]#22650

Merged
hahnjo merged 7 commits into
root-project:v6-40-00-patchesfrom
hahnjo:mac27-v640
Jun 18, 2026
Merged

[cling] Compatibility with MacOSX27.0.sdk [v6.40]#22650
hahnjo merged 7 commits into
root-project:v6-40-00-patchesfrom
hahnjo:mac27-v640

Conversation

@hahnjo

@hahnjo hahnjo commented Jun 18, 2026

Copy link
Copy Markdown
Member

Backport of #22625

frederick-vs-ja and others added 7 commits June 18, 2026 08:55
This patch renames comparators
- from `std::equal_to<llvm::rdf::RegisterRef>` to
`llvm::rdf::RegisterRefEqualTo`, and
- from `std::less<llvm::rdf::RegisterRef>` to
`llvm::rdf::RegisterRefLess`.

The original specializations don't satisfy the requirements for the
original `std` templates by being stateful and
non-default-constructible, so they make the program have UB due to C++17
[namespace.std]/2, C++20/23 [namespace.std]/5.

> A program may explicitly instantiate a class template defined in the
standard library only if the declaration
> - depends on the name of at least one program-defined type, and
> - the instantiation meets the standard library requirements for the
original template.

Backport of llvm/llvm-project@a558d65

(cherry picked from commit 3e7b8dd)
…ssary module dependency (#137432)

float.h doesn't define anything in Apple's SDKs that the clang float.h
doesn't undefine, so all the include_next does is add an unnecessary
module dependency. Skip the include_next and completely shadow the SDK
header.

Backport of llvm/llvm-project@557ddc2

(cherry picked from commit 7e4318b)
These macros were brought in as part of the TS 18661-1 integration in
C23, and then renamed in WG14 N2710.

Test coverage is being added to WG14 N3364 from C2y because that paper
was fixing a bug with the way these macros are handled with unary + and
- operators, so all the existing test coverage was there, just needed to
use a header file instead of defining the macros manually.

Fixes #162830

Backport of llvm/llvm-project@0e3fdc2

(cherry picked from commit 52497d8)
…IFINITY and NAN with float.h (#164348)

In C23 mode, both float.h and math.h are required to define INIFINITY
and NAN. However, with clang modules, there needs to be a single owner
for the declarations. Let that be float.h since that's the suggested
true owner in Annex F.2.2 of ISO/IEC 9899:2024, and introduce
`__need_infinity_nan` so that math.h can pick up the compiler
definitions.

Backport of llvm/llvm-project@38473c5

(cherry picked from commit ae49e19)
It was introduced in commit c28b205 during the upgrade to LLVM 18
to fix the build on (basically) all platforms, and this remains true
on Linux. For Apple however, the newest MacOSX27.0.sdk is incomaptible
and the option must not be set.

(cherry picked from commit a314567)
Similar to ctype.h, this is also caused by the large std module that
wraps all submodules. Instead of removing, it seems sufficient to
mark the header as textual.

(cherry picked from commit 0f5bfad)
@hahnjo hahnjo self-assigned this Jun 18, 2026
@hahnjo hahnjo requested a review from bellenot as a code owner June 18, 2026 06:58
@hahnjo hahnjo added the clean build Ask CI to do non-incremental build on PR label Jun 18, 2026
@github-actions

Copy link
Copy Markdown

Test Results

    22 files      22 suites   3d 12h 3m 31s ⏱️
 3 858 tests  3 857 ✅ 0 💤 1 ❌
77 107 runs  77 106 ✅ 0 💤 1 ❌

For more details on these failures, see this check.

Results for commit 3914741.

@hahnjo hahnjo merged commit dcdc798 into root-project:v6-40-00-patches Jun 18, 2026
35 of 42 checks passed
@hahnjo hahnjo deleted the mac27-v640 branch June 18, 2026 11:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

clean build Ask CI to do non-incremental build on PR in:Cling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants